Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed compilation of the benchmark. #201

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

aravindgopall
Copy link
Collaborator

No description provided.

@aravindgopall
Copy link
Collaborator Author

aravindgopall commented Jun 4, 2023

First work on fixing the benchmark compilation script with main focus on performance.

Future work:

  • Add benchmarks for cluster.
  • Add benchmarks in github pipeline.

@@ -46,7 +46,6 @@ import Control.Exception (Exception, IOException, evaluate, throwI
import Control.Monad
import Control.Monad.Catch (Handler (..), MonadCatch, catches, throwM)
import Control.Monad.Except
import Control.Monad.IO.Class(MonadIO(liftIO))
Copy link
Contributor

@ysangkok ysangkok Jun 4, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This import is needed on mtl-2.3, because re-exports are removed. If this line was removed to avoid a warning, I think it would be better to just make all imports use explicit import lists, instead of open imports.

That way, the code will be easier to read, and compatible with both mtl-2.2 and mtl-2.3, and there will be no warning.

For more explanation of this line, see #190

Copy link
Collaborator

@qnikst qnikst Jun 4, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There was a trick with applicative and prelude after re-exports were added that

import Control.Applicative
import Prelude

worked without warnings.

Maybe we can write:

import Control.Monad.IO.Class(MonadIO(liftIO))
import Control.Monad.Except -- the import order changed in order to avoid warnings

It may not work well with code formatters, but it should fix a warning and does not require CPP.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants